<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>管理后台</title>
    <link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/4.5.3/css/bootstrap.min.css" rel="stylesheet">
    <link rel="stylesheet" href="" th:href="@{/css/index.css}">
    <style type="text/css">

        .footer {
            width: 100%;
            height: 30px;
            line-height: 30px;
            margin-top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            /*position: absolute;*/
            z-index: 10;
            background-color: #343a40;
        }

        .footer a {
            font-family: Georgia, "Times New Roman", Times, serif;;
            color: #fff;
        }

        .navbar-nav {
            width: 300px;
            float: left !important;
            display: block !important;
        }

        .nav-item {
            padding-left: 20px;
            float: left !important;
        }

        .menua {
            font-size: 1.2em;
        }

        .menua:hover {
            background: #fff;
        }
    </style>
</head>

<body>
<!--顶部导航栏部分-->
<nav class="navbar navbar-dark sticky-top bg-dark flex-md-nowrap p-0 shadow">
    <a class="navbar-brand col-md-3 col-lg-2 mr-0 px-3"
       href="https://blog.csdn.net/Zou_05">&emsp;&emsp;&emsp;小邹喜欢Java</a>
    <button class="navbar-toggler position-absolute d-md-none collapsed" type="button" data-toggle="collapse"
            data-target="#sidebarMenu" aria-controls="sidebarMenu" aria-expanded="false" aria-label="Toggle navigation">
        <span class="navbar-toggler-icon"></span>
    </button>
    <div class="btn-group" style="margin-right: 80px">
        <input type="button" class="btn btn-secondary dropdown-toggle"
               th:value="${session.loginUser}" style="width: 160px" data-toggle="dropdown" aria-expanded="false"/>
        <div class="dropdown-menu dropdown-menu-right">
            <a th:href="@{editPassword}" target="mainFrame" style="margin-left: 22px">
                <span data-feather="home"></span>
                修改密码
            </a>
            <br/>
            <a th:href="@{userInfo}" target="mainFrame" style="margin-left: 22px">
                <span data-feather="home"></span>
                个人资料
            </a>
            <br/>
            <a th:href="@{login}" style="margin-left: 22px">
                退出
            </a>
        </div>
    </div>

</nav>

<div class="container-fluid">
    <div class="row">
        <nav id="sidebarMenu" class="col-md-3 col-lg-2 d-md-block bg-light sidebar collapse">
            <div class="sidebar-sticky pt-3">
                <ul class="nav flex-column">
                    <li class="nav-item">
                        <a class="nav-link active menua" href="loginUser" th:href="@{/loginUser}" target="mainFrame"
                           th:name="${session.loginUser}">
                            <span data-feather="home"></span>
                            用户管理 <span class="sr-only">(current)</span>
                        </a>
                        <a class="nav-link active menua" href="user" th:href="@{/user}" target="mainFrame">
                            <span data-feather="home"></span>
                            联系人信息管理 <span class="sr-only">(current)</span>
                        </a>
                        <a class="nav-link active menua" href="file" th:href="@{/file}" target="mainFrame">
                            <span data-feather="home"></span>
                            文件操作 <span class="sr-only">(current)</span>
                        </a>
                    </li>
                </ul>
            </div>
        </nav>
        <!-- 中间主体内容部分 -->
        <main class="main col-md-9 ml-sm-auto col-lg-10 px-md-4">
            <iframe src="file.html" th:src="@{/file}" id="mainFrame"
                    name="mainFrame" width="100%" height="670px" frameBorder="0">
            </iframe>
        </main>
    </div>
</div>


<!-- 底部页脚部分 -->
<div class="footer">
    <p class="text-center">
        <a href="https://blog.csdn.net/Zou_05" target="_blank"
        style="padding-left: 200px">© 2021 Zou Xiangfa Apache License 2.0 ⋅ 湘ICP备2020073177号</a>
    </p>
</div>
<script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/4.5.3/js/bootstrap.min.js"></script>
</body>

</html>